<ul id="main_menu">
    <?php foreach ($this->categories as $sitePage): ?> <?php $this->counter++; ?>
		<li class="cat-<?php echo $this->counter; ?> category"><a title="<?php echo $sitePage['h1']; ?>" href="<?php echo $this->websiteUrl . $sitePage['url'] . '.html'; ?>" ><?php echo $sitePage['navigationTitle']; ?></a>
			<?php if (is_array($sitePage['pages']) && count($sitePage['pages']) > 0): ?> <?php $faPages = array(); ?>
				<ul id="<?php echo $sitePage['url']; ?>">
					<?php foreach ($sitePage['pages'] as $page): ?>
						<li class="page">
							<a title="<?php echo $page['h1']; ?>" href="<?php echo ($page['url'] != 'index') ? $this->websiteUrl.$page['url'].'.html' : $this->websiteUrl ; ?>" ><?php echo $page['navigationTitle']; ?></a>
						</li> <?php if ($page['fa']): $faPages[] = $page; endif; ?>
					<?php endforeach; ?>
				</ul>
				<?php if (count($faPages) > 0): ?>
					<span class="menu_fa_title"><?php echo $this->name; ?></span>
					<ul class="menu_fa">
						<?php foreach ($faPages as $fa): ?>
							<li>
								<a class="menu_fa_imglink" href="<?php echo $this->websiteUrl.$fa['url'].'.html'; ?>" title="<?php echo $fa['h1']; ?>">
									<img alt="<?php echo $fa['h1']; ?>" src="<?php echo $this->escape($this->websiteUrl.$fa['path']); ?>" />
								</a>
								<a title="<?php echo $fa['h1']; ?>" href="<?php echo ($fa['url'] != 'index') ? $this->websiteUrl.$fa['url'].'.html' : $this->websiteUrl ; ?>" ><?php echo $fa['navigationTitle']; ?></a>
								<span><?php echo $fa['description']; ?></span>
							</li>
						<?php endforeach; ?>
					</ul>
				<?php endif; ?>
			<?php endif; ?>
		</li>
    <?php endforeach; ?>
</ul>